package com.funny.service;

import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.ApplicationContext;
import org.springframework.stereotype.Component;

/**
 * @author fanxiao  2021/8/9
 * @since 1.0.0
 */
@Component
@Slf4j
public class TestServiceA {

	TestServiceB serviceB;

	@Autowired
	ApplicationContext applicationContext;

	public TestServiceA(){
		log.info("TestServiceA created");
	}


	public void setServiceB(TestServiceB serviceB) {
		this.serviceB = serviceB;
	}

  	public void serviceBInfo() {
    	log.info("serviceB:{}", serviceB);
	}

	public void applicationContextInfo(){
		log.info("applicationContextInfo:{}", applicationContext);
	}

	public void setApplicationContext(ApplicationContext applicationContext) {
		this.applicationContext = applicationContext;
	}
}
